//
//  TCPManager.m
//  LazyHome
//
//  Created by yh on 2018/3/30.
//  Copyright © 2018年 yh. All rights reserved.
//

#import "TCPManager.h"

NSString *const NOTI_TCP_MESSAGE_CAME = @"NOTI_TCP_MESSAGE_CAME";
@implementation TCPManager

- (NSMutableArray<TCPClient *> *)clients{
    if (!_clients) {
        _clients = [[NSMutableArray alloc]init];
    }
    return _clients;
}
- (BOOL)tcpClient:(TCPClient *)tcpClient shouldReconnectForNetChange:(AFNetworkReachabilityStatus)networkReachabilityStatus {
    return YES;
}

- (void)tcpClient:(TCPClient *)tcpClient socket:(GCDAsyncSocket *)sock didReadData:(NSData *)data withTag:(long)tag {
    
}

- (void)tcpClient:(TCPClient *)tcpClient socket:(GCDAsyncSocket *)sock didWriteData:(NSData *)data withTag:(long)tag {
    
}

- (TCPClient *)creatClientWithHost:(NSString *)host port:(NSString *)port localport:(NSString *)localport error:(NSError *__autoreleasing *)errPtr {
    return nil;
}

- (void)sendMessage:(LHMessage *)msg toClient:(TCPClient *)clinet success:(void (^)(LHMessage *))success failure:(void (^)(void))failure {
}

@end
